package test;

public abstract class 作业2 {
    public abstract void eat();
    public abstract void sleep();

    public static void main(String[] args) {
        作业2 zuoye=new 作业2() {
            @Override
            public void eat() {
                System.out.println("吃");
            }

            @Override
            public void sleep() {
                System.out.println("睡");
            }
        };
        zuoye.eat();
        zuoye.sleep();
    }
}
